package euler.p001_050;

import euler.MainEuler;

public class Euler005 extends MainEuler {

    /*
        2520 is the smallest number that can be divided
        by each of the numbers from 1 to 10 without any remainder.

        What is the smallest positive number that is
        evenly divisible by all of the numbers from 1 to 20?
     */

    public String resolve(int number) {
        long mcm = 1;
        for (int i = 1; i <= number;i++) {
            mcm = primeHelper.MCM(mcm, i);
        }
        return String.valueOf(mcm);
    }


}
